package com.nbsaas.boot.cms.rest.convert;

import com.nbsaas.boot.cms.data.entity.DownFile;
import com.nbsaas.boot.cms.api.domain.request.DownFileRequest;

import org.springframework.beans.BeanUtils;
import com.nbsaas.boot.rest.api.Converter;
import com.nbsaas.boot.utils.BeanDataUtils;

/**
* 请求对象转换成实体对象
*/

public class DownFileEntityConvert  implements Converter<DownFile, DownFileRequest> {

    @Override
    public DownFile convert(DownFileRequest source) {
        DownFile result = new DownFile();
        BeanDataUtils.copyProperties(source, result);
        return result;
    }
}

